package com.ibangnuo.api.system;

import com.ibangnuo.framework.domain.system.SysConfig;
import com.ibangnuo.framework.model.response.ObjectResult;
import com.ibangnuo.framework.model.response.QueryResponseResult;
import com.ibangnuo.framework.model.response.ResponseResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;

/**
 * @Author: wwy
 * @Date: 2019-12-21 14:17
 */
@Api(value="配置管理",description = "配置管理，提供数据模型的增删改查")
public interface SysConfigControllerApi {
    @ApiOperation("根据type查找")
    @ApiImplicitParams({
            @ApiImplicitParam(name="type",value = "配置类型标识符",required=true,paramType="path",dataType="String"),
    })
    ObjectResult findByType(String type, String snNum);

    @ApiOperation("添加")
    ResponseResult add(SysConfig sysConfig);

    @ApiOperation("根据id更新")
    @ApiImplicitParams({
            @ApiImplicitParam(name="id",value = "配置类型主键",required=true,paramType="path",dataType="String"),
    })
    ResponseResult update(String id, SysConfig sysConfig);

    @ApiOperation("根据id删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name="id",value = "配置类型主键",required=true,paramType="path",dataType="String"),
    })
    ResponseResult delete(String id);

    @ApiOperation("查询全部")
    QueryResponseResult findAll();
}
